package cn.sunagy.security.maz.gate.server.feign;

import cn.sunagy.security.maz.api.vo.authority.PermissionInfo;
import cn.sunagy.security.maz.gate.server.config.FeignConfiguration;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.List;

/**
 * @desc：#TODO fill me ！
 * @author：三餘無夢生
 * @date：2018/6/2
 * @time：下午2:13
 */
@FeignClient(value = "ace-admin",configuration = FeignConfiguration.class)
public interface IUserFeign {
    /**
     * 获取用户的菜单和按钮权限
     * @return
     */
    @RequestMapping(value="/api/user/permissions",method = RequestMethod.GET)
    public List<PermissionInfo> getPermissionByUsername();

    /**
     * 获取所有菜单和按钮权限
     * @return
     */
    @RequestMapping(value="/api/permissions",method = RequestMethod.GET)
    List<PermissionInfo> getAllPermissionInfo();
}
